



#ifndef _PDF_UTILITY_H_
#define _PDF_UTILITY_H_

#include <wx/string.h>

#include "wx/pdfdocdef.h"

/// Class implementing several static utility methods
class WXDLLIMPEXP_PDFDOC wxPdfUtility
{
public:
    static wxString GetUniqueId(const wxString& prefix = wxEmptyString);
  
  /// Formats a floating point number with a fixed precision
  
  static wxString Double2String(double value, int precision = 0);

  /// Parses a floating point number
  
  static double String2Double(const wxString& str);

  /// Converts an integer number to a roman number
  
  static wxString Convert2Roman(int value);

  /// Forces a floating point number into a fixed range
  
  static double ForceRange(double value, double minValue, double maxValue);

  /// Converts a wxColour to the corresponding PDF specification
  
  static wxString RGB2String(const wxColour& colour);

private:
  static bool ms_seeded;    static int  ms_s1;        static int  ms_s2;      ///< Random number generator seed 2
};

#endif
